package linearlist;

/**
 * 节点
 * Created by Administrator on 2017/3/9.
 */
public class Node<E> {
    /*数据*/
    public E data;
    /*指向下一个节点的引用*/
    public Node<E> next;

    /*将进来的数据封装成一个节点（数据和引用）*/
    public Node(E data) {
        this.data = data;
        this.next = null;
    }

    /*一个数据已知下一个节点*/
    public Node(E data, Node<E> next) {
        this.data = data;
        this.next = next;
    }
}
